<?php
/*

 CCDS Configuration File

*/
$CCDS_CONFIG = array();



/*
	The CCDS can handle up to 2 MYSQL servers. If you are in a clustered 
	enviroment 	with replicated databases set replication to true and set 
	the master DB to the host that handles all update/insert/delete queries.
	The slave config applies for the slave server (SELECTs only). 
	
	The mysql abstraction layer automatically detects the mysql query type
	(select / update /...) and sends the query to the according server.
			
	Normally (w/o replication) you just have set replication to false and use 
	the slave config for your DB host. Leave the master config blank.
*/			

$CCDS_CONFIG['mysql']['replication'] = false;
$CCDS_CONFIG['mysql']['charset'] = 'UTF8';
$CCDS_CONFIG['mysql']['persistent'] = false;
$CCDS_CONFIG['mysql']['servers'] = array();

$CCDS_CONFIG['mysql']['servers']['slave'] = array();
$CCDS_CONFIG['mysql']['servers']['slave']['db'] = 'db_name';
$CCDS_CONFIG['mysql']['servers']['slave']['host'] = 'localhost';
$CCDS_CONFIG['mysql']['servers']['slave']['user'] = 'username';
$CCDS_CONFIG['mysql']['servers']['slave']['pass'] = 'password';

$CCDS_CONFIG['mysql']['servers']['master'] = array();
$CCDS_CONFIG['mysql']['servers']['master']['db'] = '';
$CCDS_CONFIG['mysql']['servers']['master']['host'] = '';
$CCDS_CONFIG['mysql']['servers']['master']['user'] = '';
$CCDS_CONFIG['mysql']['servers']['master']['pass'] = '';


/*
	If you want to gain the frontend performance beside smarty caching,
	use variable caching.
	
	Mandarin CCDS supports the following variable cachers:
	- MEMCACHED
	- APC
	- XCACHE
	
	You can even store the smarty cache files in the variable cache, but
	that's only recommend when using memcached, especially in clustered 
	enviromets. Otherwise you probably won't notice any difference.
	Do not store your smarty cache files in APC or XCACHE!

*/

$CCDS_CONFIG['varcache'] = array();
$CCDS_CONFIG['varcache']['mode'] =  'MEMCACHED';
/* time to live */
$CCDS_CONFIG['varcache']['ttl'] = 60;
/* store smarty cache in ram */
$CCDS_CONFIG['varcache']['smarty_cache'] = false;

/* only necessaray if mode is set to MEMCACHED */
$CCDS_CONFIG['varcache']['memcached_servers'] = array();

/* 
duplicate the following lines and increment the index by 1
if you'r using more than one memcached server
*/
$CCDS_CONFIG['varcache']['memcached_servers'][0] = array();
$CCDS_CONFIG['varcache']['memcached_servers'][0]['host'] = '127.0.0.1';
$CCDS_CONFIG['varcache']['memcached_servers'][0]['port'] = 11211;

/* Path webserver document root (w/o trailing slash!)*/
$CCDS_CONFIG['paths'] = array();
$CCDS_CONFIG['paths']['doc_root'] = '/var/www/html';

/* Path webserver web root (trailing slash!) */
$CCDS_CONFIG['paths']['web_root'] = '/';

/* Path from web_root to CCDS backend (trailing slash!)*/
$CCDS_CONFIG['paths']['cms_root'] = 'ccds/';

/* Path from web_root to media dir (trailing slash!)*/
$CCDS_CONFIG['paths']['media_dir'] = 'media';

/* Path from web_root to media dir (trailing slash!)*/
$CCDS_CONFIG['paths']['extension_dir'] = 'ccds_extensions/';

/* Path from web_root to the library folder (trailing slash!)*/
$CCDS_CONFIG['paths']['library_dir'] = 'ccds_library/';


$CCDS_CONFIG['global'] = array();
$CCDS_CONFIG['global']['default_lang'] = 'de';
$CCDS_CONFIG['global']['admin_email'] = 'admin@admins-domain.de';


/* CHMOD settings for created files and folders */
$CCDS_CONFIG['chmod'] = array();
$CCDS_CONFIG['chmod']['files'] = 0644;
$CCDS_CONFIG['chmod']['dirs'] = 0755;


$CCDS_CONFIG['smarty'] = array();
$CCDS_CONFIG['smarty']['cache_root'] = '/var/www/html/';
$CCDS_CONFIG['smarty']['templates'] = '/';
$CCDS_CONFIG['smarty']['compile'] = '/ccds_cache/compile/';
$CCDS_CONFIG['smarty']['cache'] = '/ccds_cache/cache/';
$CCDS_CONFIG['smarty']['config'] = '/ccds_cache/config/';


/*
	FTP

*/
$CCDS_CONFIG['ftp'] = array();
$CCDS_CONFIG['ftp']['enable'] = false;
$CCDS_CONFIG['ftp']['web_root'] = './html/';

$CCDS_CONFIG['ftp']['host'] = 'localhost';
$CCDS_CONFIG['ftp']['port'] = 21;
$CCDS_CONFIG['ftp']['user'] = 'myuser';
$CCDS_CONFIG['ftp']['pass'] = 'pass';


/*
	Image resizing
	available options: 
	IMAGICK_SHELL - uses system() to call convert on console (works in SafeMode!)
	IMAGICK_PECL - PECL extension for imagick vers 1.x (<PHP5.2)
	IMAGICK_PECL2 - PECL extention vor imagick vers 2.x (>=PHP 5.2)
*/

$CCDS_CONFIG['images'] = array();
$CCDS_CONFIG['images']['engine'] = 'IMAGICK_SHELL';
$CCDS_CONFIG['images']['path'] = 'ccds_cache/img/';

